package cn.yunyichina.provider.pay.dao;

import java.util.Map;

import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import cn.yunyichina.provider.framework.annotation.MyBatisRepository;
import cn.yunyichina.provider.framework.mvc.dao.BaseDao;
import cn.yunyichina.provider.pay.entity.HisOrderCheckedError;
import cn.yunyichina.provider.pay.vo.FinanceDetailVo;

/**
*
* @Author auto_gen_by_tool
* @CreatedTime 2016-10-26 15:28:26
*/
@Repository
@MyBatisRepository
public interface HisOrderCheckedErrorDao extends BaseDao<cn.yunyichina.provider.pay.entity.HisOrderCheckedError>{
	 
	HisOrderCheckedError selectCountAndAmount(@Param("wheres")HisOrderCheckedError wheres);

	
	/**
	 * 统计查询时，附加获取pay_type
	 * @param yytOrderNo
	 * @return
	 */
	Map<String,Object> selectForStatByOrderNo(@Param("yytOrderNo") String yytOrderNo);
	/**
	 * 指定日期范围内，某个payAppId统计金额
	 * @param beginYytPayTime
	 * @param endYytPayTime
	 * @param payAppId
	 * @param platformId
	 * @param orgId
	 * @return
	 */
	HisOrderCheckedError queryFinanceSummaryOneday(@Param("beginYytPayTime")String beginYytPayTime,@Param("endYytPayTime")String endYytPayTime,@Param("payAppId")String payAppId,@Param("platformId")String platformId,@Param("orgId")String orgId);

    FinanceDetailVo selectDetailError(@Param("orgId")String orgId, @Param("payMode")String payMode ,@Param("beginCheckTime")String beginCheckTime, @Param("endCheckTime")String endCheckTime, @Param("platformId")String platformId);

    void deleteByOrgIdAndCheckTime(@Param("orgId")String orgId,@Param("beginCheckTime")String beginCheckTime, @Param("endCheckTime")String endCheckTime);

}